package cn.schoolwow.util.module.check.common.flow;

import cn.schoolwow.quickflow.domain.FlowContext;
import cn.schoolwow.quickflow.flow.BusinessFlow;

public class CheckMessageNotEmptyFlow implements BusinessFlow {
    @Override
    public void executeBusinessFlow(FlowContext flowContext) throws Exception {
        String message = (String) flowContext.getData("message");

        if(null==message||message.isEmpty()){
            throw new IllegalArgumentException("检查提示名称不能为空");
        }
    }

    @Override
    public String name() {
        return "检查提示信息不能为空";
    }
}
